package com.ruiysoft.website.controller;

import com.ruiysoft.website.mapper.CmsMenuMapper;
import com.ruiysoft.website.service.CmsContentService;
import com.ruiysoft.website.service.CmsMenuService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.cache.annotation.Cacheable;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * Created by liudh on 2019/4/25.
 */

@RestController
@RequestMapping("menu")
public class CmsMenuController {
    @Autowired
    CmsMenuService cmsMenuService;

    @Cacheable(value="selectListByEnterpriseIdAndParentCode")
    @GetMapping("selectListByEnterpriseIdAndParentCode")
    public Object selectListByEnterpriseIdAndParentCode(String enterpriseId, String parentCode) {
        return cmsMenuService.selectList(enterpriseId, parentCode);
    }
}

